<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <title>Dom.attribute</title>
    <script src="../src/dom.js"></script>
</head>
<body>
<div id="test">click me</div>
<ul>
    <li class="li1"><a href="#1">click me</a></li>
    <li class="li2"><a href="#2">click me</a></li>
    <li class="li3"><a href="#3">click me</a></li>
</ul>

<script type="text/javascript">
    console.log(Dom.attribute(Dom.findByTagName('div')[0], 'id'));//returns test
    console.log(Dom.attribute(Dom.findByTagName('div')[0], {lang: "en"}));//sets lang attribute to "en"
    console.log(Dom.attribute(Dom.findByTagName('div')[0], ['id', 'lang']));//will return object {id: test, lang: en}
</script>
</body>
</html>